#include<iostream>
#include<string>


#include<time.h>

using namespace std;

int main()
{
    time_t now1 = time(0);
    long now2;
    time(&now2);
    cout<<now1<<endl;
    cout<<now2<<endl;

    struct tm tmnow;
    localtime_r(&now1,&tmnow);
    string stime = to_string(tmnow.tm_year+1900)+"-"
    +to_string(tmnow.tm_mon+1)+"-"
    +to_string(tmnow.tm_mday)+" "
    +to_string(tmnow.tm_hour)+":"
    +to_string(tmnow.tm_min)+":"
    +to_string(tmnow.tm_sec);
    cout<<stime<<endl;
    return 0;
}